<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8" import="java.util.*"%>
<%@page import="java.sql.*" %>
<jsp:useBean id="dbcon" class="dao.DBcon" scope="request"/>
<!DOCTYPE html >
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>上传数据库</title>
</head>
<body>
	<%
	request.setCharacterEncoding("utf-8");
	String user=request.getParameter("username");
	String pass=request.getParameter("pwd");
	
	
	%>
	 <%   
	 Connection conn=dbcon.getConnection(); 
     PreparedStatement sql =conn.prepareStatement("insert into login(username,password) values(?,?)");  
     sql.setString(1,user);  
     sql.setString(2,pass);
     sql.executeUpdate(); 
     sql.close();
     conn.close();  
    %>  
   
</body>
</html>